//ACCEPTED
#include <cstdio>
#include <cstring>

char c[201];

void read(){
	scanf("%s", &c);
}
void process(){
	int i, s=strlen(c);
	//printf("%d", s);
	for(i=0;i<s;i++){
		if(c[i]=='.')printf("0");
		else if(c[++i]=='.')printf("1");
		else printf("2");
	}
}

int main(){
	//freopen("in.txt", "r", stdin);
	//freopen("out.txt", "w", stdout);
	read();
	process();
	return 0;
}
